#
# test
#
ADD_EXECUTABLE(tchem-surf-test.x TChem_Test_Driver.cpp)
TARGET_LINK_LIBRARIES(tchem-surf-test.x ${TCHEM_LINK_LIBRARIES})

#
# Testing method should be improved
#
FILE(GLOB TCHEM_TEST_DATA "input/PT/*")
FILE(COPY ${TCHEM_TEST_DATA}
     DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/input/PT)

INSTALL(FILES ${TCHEM_TEST_DATA}
        PERMISSIONS OWNER_READ OWNER_WRITE
        DESTINATION "${CMAKE_INSTALL_PREFIX}/${TCHEM_INSTALL_TEST_PATH}/surface/input/PT")

INSTALL(TARGETS tchem-surf-test.x
        PERMISSIONS OWNER_EXECUTE OWNER_READ OWNER_WRITE
        DESTINATION "${CMAKE_INSTALL_PREFIX}/${TCHEM_INSTALL_TEST_PATH}/surface")

ADD_TEST(TChemTest tchem-surf-test.x)
